import Layout from '@/layout/index.vue'

const systemRouter = [{
  path: '/system',
  component: Layout,
  isShow: true,
  redirect: 'noRedirect',
  name: 'system',
  alwaysShow: true,
  meta: { title: '系统管理', icon: 'Operation', },
  children: [
    {
      path: 'user',
      component: () => import('@/views/system/user/user.vue'),
      name: 'user',
      meta: { title: '用户管理', permissions: ['core:user:'], icon: 'document' }
    },
    // {
    //   path: 'tenant',
    //   component: () => import('@/views/system/tenant/tenant.vue'),
    //   name: 'tenant',
    //   meta: { title: '租户管理', roles: ['admin'], icon: 'document' }
    // },
    // {
    //   path: 'dept',
    //   component: () => import('@/views/system/dept/dept.vue'),
    //   name: 'dept',
    //   meta: { title: '部门管理', permissions: ['core:department:'], icon: 'document' }
    // },
    {
      path: 'role',
      component: () => import('@/views/system/role/role.vue'),
      name: 'role',
      meta: { title: '角色管理', roles: ['admin'], icon: 'document' }
    },
    {
      path: 'menu',
      component: () => import('@/views/system/menu/menu.vue'),
      name: 'menu',
      meta: { title: '权限管理', roles: ['admin'], icon: 'document' }
    },
    // {
    //   path: 'dict',
    //   component: () => import('@/views/system/dict/dict.vue'),
    //   name: 'dict',
    //   meta: { title: '字典管理', roles: ['admin'], icon: 'document' }
    // }
  ]
}, {
  path: '/system',
  component: Layout,
  hidden: true,
  children: [
    {
      path: 'dict-data/:id',
      component: () => import('@/views/system/dict/data.vue'),
      name: 'dict-data',
      meta: { title: '字典数据', role: ['other'] }
    }
  ]
}]

export default systemRouter
